<%-- 
    Document   : signup2
    Created on : Dec 13, 2012, 1:24:33 PM
    Author     : rzclau
--%>

<%@page contentType="text/html" pageEncoding="UTF-8"%>
<!DOCTYPE html>
<%@page import="model.UserBean" %>
<% UserBean bean;
    bean = new UserBean();
    //get request from servlet if data is invalid
    if (request.getAttribute("error") != null) {
        out.println("error");
        bean = (UserBean) request.getAttribute("error");
    }
    if (request.getAttribute("updateuser") != null) {
        bean = (UserBean) request.getAttribute("updateuser");
    }
%>
<html>
    <head>
        <meta charset="utf-8" />

        <title>PENDAFTARAN ANGGOTA COSTUME-IZER</title>
        <link rel="stylesheet" href="portfolio/assets/css/styles.css" />

    </head>
    <body><center>
        <form action=ControllerServlet method="post"><br>
            <TABLE>
                <tr>
                    <td colspan="3"><div
                            align="center" class="style15">
                            <p>PENDAFTARAN ANGGOTA COSTUME-IZER</p>
                        </div></td>
                <tr>
                <TR>
                <tr>
                    <TD>Nama</TD>
                    <TD><INPUT TYPE=TEXT NAME=Nama size=40 value="<%=bean.getNama()%>" <%=request.getAttribute("updateuser") != null ? "readonly" : ""%>></TD>
                    <TD width="350px">
                        <font color="red"><%=bean.getNamaError()%> &nbsp;</font>
                    </TD>
                </tr>
                <tr>
                    <TD>Alamat</TD>
                    <TD><TEXTAREA NAME=Alamat cols="31" ><%=bean.getAlamat()%></TEXTAREA>
                    </TD>
                    <TD width="350px">
                        <font color="red"><%=bean.getAlamatError()%> &nbsp;</font>
                    </TD>
                </tr>
                <br>
                <br>
                <tr>
                    <TD>No. Telpon</TD>
                    <TD><INPUT TYPE=TEXT NAME=NoTelp size=40 value="<%=bean.getNoTelp()%>"></TD>
                    <TD width="350px">
                        <font color="red"><%=bean.getNoTelpError()%> &nbsp;</font>
                    </TD>
                </tr>
                <br>
                <br>
                <tr>
                    <TD>Jenis Kelamin</TD>
                    <TD>
                        <p>
                            <label>
                                <input type="radio" name=JenisKelamin value="M" checked>
                                Laki-laki</label>
                            <label>
                                <input name=JenisKelamin type="radio" value="F">
                                Perempuan</label>
                        </p></TD>
                    <TD width="350px">
                        <font color="red"><%=bean.getJenisKelaminError()%> &nbsp;</font>
                    </TD>
                </tr>
                <br>
                <br>
                <tr>
                    <TD>E-mail</TD>
                    <TD><INPUT TYPE=TEXT NAME=Email size=40 value="<%=bean.getEmail()%>"></TD>
                    <TD width="350px">
                        <font color="red"><%=bean.getEmailError()%> &nbsp;</font>
                    </TD>
                </tr>
                <br>
                <br>
                <tr>
                    <TD>Username</TD>
                    <TD><input type=TEXT name=Username size=40 value="<%=bean.getUsername()%>" <%=request.getAttribute("updateuser") != null ? "readonly" : ""%>></TD>
                    <TD width="350px">
                        <font color="red"><%=bean.getUsernameError()%> &nbsp;</font>
                    </TD>
                </tr>
                <br>
                <br>
                <tr>
                    <TD>Password</TD>
                    <TD><INPUT TYPE=PASSWORD NAME=Password size=40 value="<%=bean.getPassword()%>"></TD>
                    <TD width="350px">
                        <font color="red"><%=bean.getPasswordError()%> &nbsp;</font>
                    </TD>
                </tr>
                <br>
                <br>
                <tr>
                <tr>
                    <TD><p>&nbsp;</p>
                        <p>&nbsp;</p></TD>
                    <TD><input NAME=action type=submit value="<%=bean.getAction()%>"></TD>
                </tr>
                <br>
                <br>
            </TABLE>
            </font>
        </form>
    </center>
    <footer>
        <h2>Sistem Informasi Persewaan Kostum - COSTUME-IZER</h2>

    </footer>

    <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.6.1/jquery.min.js"></script>
    <script src="portfolio/assets/js/jquery.quicksand.js"></script>
    <script src="portfolio/assets/js/script.js"></script>
</body>
</body>
</html>